<!DOCTYPE html>
<html lang="pt-br">
    <head>
        <meta charset="UTF-8">
        <title>Lista produtos</title>
        <link rel="stylesheet" href="../css/Tables.css" />
    </head>
    <body>
        <?php
        require ("../../_app/Config.inc.php");
        $read = new Read();
        $read->ExeRead('estoque');
        ?>
        <fieldset>
            <form name="ListProdEst" action="" method="POST" >
                <label><b>Categoria</b></label>
                <select>
                    <option></option>
                    <option name="cachorro">Cachorro</option>
                    <option name="peixe">Peixe</option>
                    <option name="passaros">Passaros</option>
                </select>
                
                <label><b>Pesquisar:</b></label>
                <input type="text" name="pesquisa" />
                <input type="button" name="pesquisando" value="Pesquisar" />
                
            </form>
            
        </fieldset>
        <?php 
        echo "<table class=\"tabelaEst\"><tr><th>Id</th><th>Produto</th><th>Quantidade</th><th>Valor Produto</th><th>Descrição</th>";
        if($read->getResult()):
            foreach ($read->getResult() as $res):
                echo "<tr><td>{$res['id_Est']}</td><td>{$res['Nome_Prod_Est']}</td><td>{$res['Quantidade_Est']}</td><td>{$res['Valor_Prod_Est']}</td><td>{$res['Descricao']}</td></tr>";
            endforeach;
        endif;
        echo "</table>";
        ?>
        <table>
        
        </table>
    </body>
</html>
